Skip to content

fix(release): the no-account pusher check reads its file directly, with no pipe - #8095

Merged
miguel-heygen merged 1 commit into
mainfrom
fix/release-pusher-check-no-pipe
Nov 17, 2026
Merged

miguel-heygen merged 1 commit into
mainfrom
fix/release-pusher-check-no-pipe

Conversation

@miguel-heygen

@miguel-heygen miguel-heygen commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

What changed

The release gate's check for a push recorded with no account (#8076) now reads the pusher list with one grep, not cut | grep.

The step runs with -o pipefail. In the piped form, if grep -q matched and exited while cut was still writing, cut would die of SIGPIPE. The pipeline would then return 141, and the leading ! would turn that into a pass: the check would fail open. The list is a few short lines, so this can't happen in practice today. The pipe-free form has no such path. A null login writes a line starting with a tab, which ^\t matches.

What I measured

On the devbox (Node 24), scripts/publish-workflow.test.mjs passes 26/26 three times at the head. With the check removed, "a push with no recorded account" fails (25/26).

fails without the fix: scripts/publish-workflow.test.mjs "a push with no recorded account" (25/26 with the check removed). The SIGPIPE path itself is a pipe race and can't be unit-tested.

No visible change

CI workflow only.

@jrusso1020 jrusso1020 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed at 4db65778. The change is exactly my #8076 suggestion. ! grep -q $'^\t' "$RUNNER_TEMP/pushers.tsv" has no pipe, so a SIGPIPE can't turn into a pass. A null login writes a line that starts with a tab, which ^\t matches. The step runs under bash, so $'…' expands. scripts/publish-workflow.test.mjs passed 26/26 with this exact line when I reviewed #8076.

Request changes (body only): the lane requires a literal fails without the fix: line naming a test, and the body doesn't have one. The SIGPIPE race itself can't be unit-tested, so naming the guard is enough. Something like:

fails without the fix: scripts/publish-workflow.test.mjs "a push with no recorded account" (25/26 with the check removed); the SIGPIPE path itself is a pipe race and isn't unit-testable.

Once that line is in, I'll approve. No code change is needed. CI so far: nothing failed.

Verdict: REQUEST_CHANGES (body line only). Needs reuse: no. Over-engineered: no.

— Rames

@jrusso1020 jrusso1020 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approve at 4db65778. My only finding was the missing fails without the fix: line. The body now names scripts/publish-workflow.test.mjs "a push with no recorded account" (25/26 with the check removed), and it explains why the SIGPIPE path can't be unit-tested. The head is unchanged from the code I reviewed, and CI is green.

@miguel-heygen
miguel-heygen added this pull request to the merge queue Nov 17, 2026
Merged via the queue into main with commit 7407968 Nov 17, 2026
111 of 113 checks passed
@miguel-heygen
miguel-heygen deleted the fix/release-pusher-check-no-pipe branch November 17, 2026 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants